<template>
  <el-container class="container layout">
    <el-header class="el-header">
      <a href="/" class="logo">
        原型平台
      </a>
      <div class="bar">
        <el-button type="warning" size="small" @click="link('project')">
          新增项目
        </el-button>
      </div>
    </el-header>
    <el-container class="main-container">
      <el-main class="main">
        <nuxt />
      </el-main>
    </el-container>
  </el-container>
</template>

<script>
export default {
  data() {
    return {
      isCollapse: false,
      title: '',
      listData: []
    }
  },
  methods: {
    link(type) {
      if (type === 'model') {
        this.$router.push({
          path: '/modelDetail'
        })
      } else if (type === 'project') {
        this.$router.push({
          path: '/projectDetail'
        })
      } else {
        this.$router.push({
          path: '/projectDetail'
        })
      }
    }
  }
}

</script>

<style lang="scss">
//@import url("element-ui/lib/theme-chalk/index.css");

</style>
